README – Replication Materials

Article: “Reliability as Resolve: Reputational Transference in International Relations”
Journal: Journal of Peace Research
Author: Md Muhibbur Rahman


1. Overview

This archive contains the data and code necessary to replicate the empirical results and figures in the main text and online appendix of the article.

All regression models reported in the main text and online appendix (except the GTATE models) are implemented in Stata.

Figures and GTATE models/graphs are implemented in Python using Jupyter notebooks.

Figure 1 (map) requires one additional shapefile and one country-code file, in addition to the main replication dataset.

Replication requires changing file paths in the Stata and Python code to match the user’s local directory structure.



2. Files in this Archive

2.1 Data

jpr_replication_data.dta
Main dataset used for all models and figures (except for the additional inputs required for the map in Figure 1).

ne_110m_admin_0_countries.shp (+ associated shapefile files)
Natural Earth country polygons used to produce the world map in Figure 1.

COW-country-codes.csv
Correlates of War country code crosswalk used to merge the replication data with the shapefile for Figure 1.

Note: The shapefile consists of multiple files (e.g., .shp, .dbf, .shx, etc.). All associated files must be in the same folder for the code to run properly.

2.2 Stata Code

dofile_models.do
Stata do-file that replicates all regression models (main text and online appendix), except the GTATE models.

This file:

Loads jpr_replication_data.dta.

Runs the models corresponding to the tables in the article and online appendix.

Produces the table outputs (e.g., regression tables).

2.3 Python / Jupyter Code

figure_1_code.ipynb (or similarly named Jupyter notebook)
Jupyter notebook that produces Figure 1 (map).

Requires:

jpr_replication_data.dta

ne_110m_admin_0_countries.shp (and associated files)

COW-country-codes.csv

<other_figure_notebooks>.ipynb
Jupyter notebook(s) that produce the remaining figures in the main text and online appendix, including GTATE models and graphs.

These notebooks require only:

jpr_replication_data.dta

Please refer to the comments at the top of each notebook for the specific figure/table references.


3. Software Requirements

Stata (SE/MP; recent version capable of handling factor variables and modern regression commands).

Python 3.x with:

pandas
numpy
statsmodels
matplotlib
geopandas (for the map in Figure 1)
Any additional packages noted at the top of the Jupyter notebooks.
Jupyter Notebook (via Anaconda, VS Code, or another environment).\



4. Replication Instructions

4.1 General Setup

Download and unzip all files into a single working directory (or a directory structure of your choice).

Open each Stata do-file and Python notebook and edit the file paths so that they correctly point to:

The directory containing jpr_replication_data.dta
The directory containing the shapefile (ne_110m_admin_0_countries.*)
The directory containing COW-country-codes.csv
The desired output directory for tables and figures.

Typical paths to update are variables such as data_path, cow_path, shapefile_path, and any output_path options defined near the top or associated with each of the figures produced.



4.2 Replicating Regression Models (Main Text & Online Appendix)

Open Stata.
Set the working directory to the folder containing dofile_models.do and jpr_replication_data.dta, e.g.:

cd "C:\path\to\your\replication\folder"

Open dofile_models.do

Run the in the do-file command associated with each table:


4.3 Replicating Figures and GTATE Models/Graphs


(a) Figure 1 – Map

Open figure_1_code.ipynb in Jupyter.

Update under load dataset around the beginning of the notebook (after loading the packages):

data_path = r"C:\path\to\jpr_replication_data.dta"
cow_path = r"C:\path\to\COW-country-codes.csv"
shapefile_path = r"C:\path\to\ne_110m_admin_0_countries.shp"

Around the bottom end, update:
save_path = r"C:\path\to\output\folder"

Run all cells in the notebook.

The notebook will:

Merge the replication data with the shapefile using the COW country codes.
Produce the map used as Figure 1 in the article.
Save the figure as a .png file in the specified save_path.



(b)  Figures 2 

Open figure_2_code.ipynb in Jupyter.
Update under load dataset around the beginning of the notebook (after loading the packages)
file_path = r"C:\path\to\jpr_replication_data.dta"

Update the path within the command plt.savefig() (around the end, before the plt.show command).

This notebook will:
Produce the figure used as Figure 2 in the article.
Save the figure as a .png file in the specified folder.



(c)  Figures 3 and 4 (GTATE Models)

Open the relevant Jupyter notebook: figures_3_and_4_code.ipynb

At the top of the notebook, update:

file_path = r"C:\path\to\jpr_replication_data.dta"

Update the paths within the command plt.savefig() associated with each figure (they are around the end, before the plt.show command for each figure)

Run all cells. Make sure to run all the codes in the subsequent order, starting from the beginning of Figure 3, to be able to produce Figure 4.

This notebook will:
Estimate the pretreatment trends, the GTATE models, and ATT graphs.
Produce Figures 3 and 4 as reported in the main text.
Save the resulting figures in the specified folder.



5. Notes and Contact

For questions about the replication materials, please contact:

Md Muhibbur Rahman
Email: mrahman5@upenn.edu